{smcl}
{* 20jun2003}{...}
{hline}
help for {hi:mynormal}{...}
{right:Example estimation command from the ML book, 2d ed.}
{hline}

{title:The normal model}

{p 8 12 2}
{cmd:mynormal}
	{it:depvar}
	[{it:varlist}]
	[{it:weight}]
	[{cmd:if} {it:exp}]
	[{cmd:in} {it:range}]
	[{cmd:,}
	{cmdab:const:raints:(}{it:numlist}|{it:matname}{cmd:)}
	{cmdab:het:ero:(}{it:varlist}{cmd:)}
	{cmdab:r:obust}
	[ {cmdab:cl:uster:(}{it:varname}{cmd:)} | {cmd:svy} {it:svy_options} ]
	{cmdab:l:evel:(}{it:#}{cmd:)}
	{cmd:nolrtest}
	{cmdab:nolo:g}
	{cmdab:nocons:tant}
	[
		{cmdab:off:set:(}{it:varname}{cmd:)} 
		|
		{cmdab:exp:osure:(}{it:varname}{cmd:)} 
	]
	{it:maximize_options}
	]


{p 4 4 2}
{it:svy_options} are:

{p 8 8 2}
	{cmdab:sub:pop:(}{it:varname}{cmd:)}
	{cmdab:srs:subpop}
	{cmdab:nosvy:adjust}
	{cmdab:p:rob}
	{cmd:ci}
	{cmd:deff}
	{cmd:deft}
	{cmd:meff}
	{cmd:meft}

{p 4 4 2}
{cmd:fweight}s and {cmd:pweight}s are allowed; see help {help weights}.

{p 4 4 2}
{cmd:mynormal} shares the features of all estimation commands; see help
{help estcom}.

{p 4 4 2}
Options that may be used when redisplaying results are:

{p 8 8 2}
	{cmdab:l:evel:(}{it:#}{cmd:)}
	{cmdab:p:rob}
	{cmd:ci}
	{cmd:deff}
	{cmd:deft}
	{cmd:meff}
	{cmd:meft}


{title:Description}

{p 4 4 2}
{cmd:mynormal} uses {cmd:ml} to fit a normal model.


{title:Options}

{p 4 8 2}
{cmd:constraints(}{it:numlist}|{it:matname}{cmd:)} specifies the
linear constraints to be applied for the model fit.
{cmd:constraints(}{it:numlist}{cmd:)} specifies the constraints by number.
{cmd:constraints(}{it:matname}{cmd:)} specifies a matrix that contains the
constraints.
Constraint numbers are defined using the
{cmd:constraint} command and are numbered; see help {help constraint}.  The
default is to perform unconstrained estimation.

{p 4 8 2}
{cmd:hetero(}{it:varlist}{cmd:)} specifies variables to model
heteroscedasticity in the errors.  By default {cmd:mynormal} fits a
homoscedastic model.

{p 4 8 2}
{cmd:robust} specifies that the Huber/White/sandwich estimator of
variance is to be used in place of the traditional calculation; see
{hi:[U] 23.14 Obtaining robust variance estimates}.  {cmd:robust} combined
with {cmd:cluster()} allows observations which are not independent within
cluster (although they must be independent between clusters).

{p 4 8 2}
{cmd:cluster(}{it:varname}{cmd:)} specifies that the observations are
independent across groups (clusters) but not necessarily independent within
groups.  {it:varname} specifies to which group each observation belongs; e.g.,
{cmd:cluster(personid)} in data with repeated observations on individuals.
Specifying {cmd:cluster()} implies {cmd:robust}.  This option may not be
combined with the {cmd:svy} option.

{p 4 8 2}
{cmd:svy} indicates that {cmd:mynormal} is to pick up the {cmd:svy} settings set
by {cmd:svyset} and use the robust variance estimator.  Thus, this option
requires the data to be {cmd:svyset}; see help {help svyset}.  {cmd:svy} may
not be supplied with {it:weight}s or the {cmd:cluster()} option.

{p 8 8 2}
The following options are available with the {cmd:svy} option:

{p 8 12 2}
{cmd:subpop(}{it:varname}{cmd:)} specifies that estimates be computed
for the single subpopulation defined by the observations for which
{it:varname}!=0.  Typically, {it:varname}=1 defines the subpopulation and
{it:varname}=0 indicates observations not belonging to the subpopulation.  For
observations whose subpopulation status is uncertain, {it:varname} should be
set to missing.

{p 8 12 2}
{cmd:srssubpop} can only be specified if {cmd:subpop()} is specified.
{cmd:srssubpop} requests that deff and deft be computed using an estimate of
simple-random-sampling variance for sampling within a subpopulation.  If
{cmd:srssubpop} is not specified, deff and deft are computed using an estimate
of simple-random-sampling variance for sampling from the entire population.
Typically, {cmd:srssubpop} would be given when computing subpopulation
estimates by strata or by groups of strata.

{p 8 12 2}
{cmd:nosvyadjust} specifies that the model Wald test be carried out as W/k
distributed F(k,d), where W is the Wald test statistic, k is the number of
terms in the model excluding the constant, d = total number of sampled PSUs
minus total number of strata, and F(k,d) is an F distribution.  By default, an
adjusted Wald test is conducted:  (d-k+1)W/(kd) distributed F(k,d-k+1).  Use
of the {cmd:nosvyadjust} option is not recommended.

{p 8 12 2}
{cmd:prob} requests that the t statistic and p-value be displayed.  The
degrees of freedom for the t are d = total number of sampled PSUs minus the
total number of strata (regardless of the number of terms in the model).  If
no display options are specified then, by default, the t statistic and p-value
are displayed.

{p 8 12 2}
{cmd:ci} requests that confidence intervals be displayed.  If no
display options are specified then, by default, confidence intervals are
displayed.

{p 8 12 2}
{cmd:deff} requests that the design-effect measure deff be displayed.
See {hi:[SVY] svymean} for details.

{p 8 12 2}
{cmd:deft} requests that the design-effect measure deft be displayed.
See {hi:[SVY] svymean} for details.

{p 8 12 2}
{cmd:meff} requests that the meff measure of misspecification effects
be displayed.  This option must be specified at the time of the initial
estimation.  See {hi:[SVY] svymean} for details.

{p 8 12 2}
{cmd:meft} requests that the meft measure of misspecification effects
be displayed.  This option must be specified at the time of the initial
estimation.  See {hi:[SVY] svymean} for details.

{p 4 8 2}
{cmd:level(}{it:#}{cmd:)} specifies the confidence level, in percent,
for the confidence intervals of the coefficients; see help {help level}.

{p 4 8 2}
{cmd:nolrtest} indicates that the model significance test should be a Wald
test instead of a likelihood-ratio test.  This prevents the constant-only
model to be fit.  Note that options resulting in robust variance estimates and
{cmd:constraints()} imply this option.

{p 4 8 2}
{cmd:nolog} suppresses the iteration log.

{p 4 8 2}
{cmd:noconstant} suppresses the constant term (intercept) in the model.

{p 4 8 2}
{cmd:offset(}{it:varname}{cmd:)} specifies that the equation is to be
xb + {it:varname}; that the equation is to include {it:varname} with
coefficient constrained to be 1.

{p 4 8 2}
{cmd:exposure(}{it:varname}{cmd:)} is an alternative to {cmd:offset()};
it specifies that the equation is to be xb + ln({it:varname}).  The equation
is to include ln({it:varname}) with coefficient constrained to be 1.

{p 4 8 2}
{it:maximize_options} control the maximization process; see help
{help maximize}.  You should never have to specify them.


{title:Also see}

{p 4 14 2}
On-line:  help for {help normal}, {help svynormal}, {help constraint}
